class LadderRenderer : public IBlockRenderer
{
public:
	ITexture *Texture;

	LadderRenderer(ITexture *texture) :
		Texture(texture)
	{
	}

	int GetTypeData(const int &data) { return 0; }

	void Render(Schematic *schematic, RendererBase *renderer, const Block &block, const Point3i &position)
	{
		renderer->Translate(8, 8, 8);

		switch (block.Data)
		{
		case 3:
			renderer->Rotate(180, 0, 1, 0);
			break;
		case 4:
			renderer->Rotate(90, 0, 1, 0);
			break;
		case 5:
			renderer->Rotate(-90, 0, 1, 0);
			break;
		}

		renderer->Translate(-8, -8, -8);

		renderer->Draw(Face(Point3f(16, 0, 15), Point3f(0, 0, 15), Point3f(0, 16, 15), Point3f(16, 16, 15), Colorb::White, Texture, Point2i(3 * 16, 5 * 16), 16, 16));
	}
};